module.exports = {
	//获取首页数据
	getInfo:function(param = {}){
		let test = this._getTest(param)
		return this._return({
			//广告
			elan_list:[
				{id:1001,thumb:'/static/temp.jpg',value:'https://mp.weixin.qq.com/s/h_z-jeraXWz0FoGoR41NVg'},
				{id:1002,thumb:'/static/temp.jpg',value:'https://mp.weixin.qq.com/s/h_z-jeraXWz0FoGoR41NVg'},
			],
			//filter
			brand_list:[
				{id:1001,text:test+'-brand1',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-brand2',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-brand3',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-brand4',icon:'/static/temp.jpg'},
			],
			//filter
			shape_list:[
				{id:1001,text:test+'-shape1',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-shape2',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-shape3',icon:'/static/temp.jpg'},
				{id:1001,text:test+'-shape4',icon:'/static/temp.jpg'},
			],
			//filter
			text_list:[
				{id:1001,text:test+'-text1'},
				{id:1001,text:test+'-text2'},
				{id:1001,text:test+'-text3'},
				{id:1001,text:test+'-text4'},
			],
			//首页列表
			list:this._getList(param),
		});
	},
	readData:function(param = {}){
		let test = this._getTest(param)
		return {
			info:{
				//首页列表
				list:this._getList(param),
			},
			success:true,
			state:"normal",
		}
	},
	_getList(param){
		let test = this._getTest(param)
		let item = {
			id: 1002,
			thumb:'/static/temp.jpg',
			sign:'/static/temp.jpg',
			title:test+'ssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss',
			more:test+'xxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
			price_text:test+'32$$$$',
			price_info:test+'xxxxxxxxxxx',
		}
		let list = []
		for(var i= 0;i<5;i++)
			list.push(item)
		return list;
	},
	_getTest(param){
		let test = '测试'
		if(param.lan=='uy')test = 'سىناق'
		return test
	},
	_return(info){
		return {
			info:info,
			success:true,
			state:"normal",
		}
	},
}